/**
 * 显示文章的webview
 */
import React from 'react';
import
{
    View,
    Text,
    TouchableHighlight,
    Image,
    WebView,
}
    from 'react-native';

import  BaseComponent, {base} from '../../base/Base' ;

let {USER_INFO}=base.fields;
export default class FindArticalPage extends BaseComponent {

    static navigationOptions = ({navigation}) => ({
        title:navigation.state.params.articalData.title,
    });
    constructor(props) {
        super(props);
      let data=  this.props.navigation.state.params.articalData;
      this.state={
          linkUrl:data.linkUrl,
          articalData:data,
      }
    }

    componentDidMount() {
    }

    render() {
        let url=this.state.linkUrl;
           return (
               <WebView
                   domStorageEnabled={true}
                   decelerationRate="normal"
                   startInLoadingState={true}
                   source={{uri: url}}
                   style={{width:'100%',height:'100%'}}
                   scrollEnabled={false}
                   bounces={false}
                   contentInset={{top: 0, left: 0}}
                   automaticallyAdjustContentInsets={true}
                   javaScriptEnabled={true}
                   onNavigationStateChange={(navState) => {
                   }}
               />
           )

    }


}

